package com.lagou.pojo;

import com.alibaba.fastjson.annotation.JSONField;
import lombok.Data;
import lombok.Getter;
import lombok.Setter;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 *  课程章节
 * */
@Data
public class Course_Section  implements Serializable {

  //课程章节id
  @JSONField(ordinal = 1)
  private int id;

  //课程id
  @JSONField(ordinal = 2)
  private int course_id;

  //章节名
  @JSONField(ordinal = 3)
  private String section_name;

  //章节描述
  @JSONField(ordinal = 4)
  private String description;

  //排序
  @JSONField(ordinal = 5)
  private long order_num;

  //章节状态，0:隐藏；1：待更新；2：已发布
  @JSONField(ordinal = 6)
  private long status;

  //创建时间
  @JSONField(ordinal = 7)
  private String create_time;

  //修改时间
  @JSONField(ordinal = 8)
  private String update_time;

  //是否删除 0-未删除，1-已删除
  @JSONField(ordinal = 9)
  private int isDel;

  //添加一个Course类型的属性
  private Course course;

  //添加一个list集合 泛型是 Course_lesson
  List<Course_Lesson> lessonList = new ArrayList<>();

  public int getId() {
    return id;
  }

  public void setId(int id) {
    this.id = id;
  }

  public int getCourse_id() {
    return course_id;
  }

  public void setCourse_id(int course_id) {
    this.course_id = course_id;
  }

  public String getSection_name() {
    return section_name;
  }

  public void setSection_name(String section_name) {
    this.section_name = section_name;
  }

  public String getDescription() {
    return description;
  }

  public void setDescription(String description) {
    this.description = description;
  }

  public long getOrder_num() {
    return order_num;
  }

  public void setOrder_num(long order_num) {
    this.order_num = order_num;
  }

  public long getStatus() {
    return status;
  }

  public void setStatus(long status) {
    this.status = status;
  }

  public String getCreate_time() {
    return create_time;
  }

  public void setCreate_time(String create_time) {
    this.create_time = create_time;
  }

  public String getUpdate_time() {
    return update_time;
  }

  public void setUpdate_time(String update_time) {
    this.update_time = update_time;
  }

  public int getIsDel() {
    return isDel;
  }

  public void setIsDel(int isDel) {
    this.isDel = isDel;
  }

  public Course getCourse() {
    return course;
  }

  public void setCourse(Course course) {
    this.course = course;
  }

  public List<Course_Lesson> getLessonList() {
    return lessonList;
  }

  public void setLessonList(List<Course_Lesson> lessonList) {
    this.lessonList = lessonList;
  }

  public int getLast_operator_id() {
    return last_operator_id;
  }

  public void setLast_operator_id(int last_operator_id) {
    this.last_operator_id = last_operator_id;
  }

  public int getIs_visible() {
    return is_visible;
  }

  public void setIs_visible(int is_visible) {
    this.is_visible = is_visible;
  }

  public String getLast_operator() {
    return last_operator;
  }

  public void setLast_operator(String last_operator) {
    this.last_operator = last_operator;
  }

  @Override
  public String toString() {
    return "Course_Section{" +
            "id=" + id +
            ", course_id=" + course_id +
            ", section_name='" + section_name + '\'' +
            ", description='" + description + '\'' +
            ", order_num=" + order_num +
            ", status=" + status +
            ", create_time='" + create_time + '\'' +
            ", update_time='" + update_time + '\'' +
            ", isDel=" + isDel +
            '}';
  }

  @JSONField(serialize = false)
  private int last_operator_id; //最后操作者ID
  @JSONField(serialize = false)
  private int is_visible; //是否可见
  @JSONField(serialize = false)
  private String last_operator; //最后操作者

}
